package com.burns.jdk8.tk;/**
 * Created by burns.
 *
 * @author <a href="http://www.esoon-soft.com/">burns</a>
 * @date 2022/01/19 14:01
 */

import java.io.IOException;
import java.util.Properties;
import java.util.Set;
import java.util.logging.Level;
import java.util.logging.Logger;

/**
 * @Description TODO
 * @ClassName LoggerTest
 * @Author Burns
 * @DAte 2022/1/19 14:01
 */
public class LoggerTest {
    private static final Logger myLogger = Logger.getLogger("xyz");
    public static void main(String[] args){
//        Logger.getGlobal().setLevel(Level.OFF);
        Logger.getGlobal().info("File->Open menu item selected");
        Logger.getGlobal().warning("666");
        myLogger.info("111");
        myLogger.log(Level.ALL,"333",new IOException());

        Properties properties = System.getProperties();

        Object o = properties.get("java.util.logging.config.file");
        System.out.println(o);
        System.out.println("~~~~~~~~~~~~~~~~");

        Set<Object> objects = properties.keySet();
        for(Object key:objects){
            Object value = properties.get(key);
            System.out.println(key+"~~~~~~~~~"+value);
        }


    }
}
